<?php

class TickerManager{
	private $session;
	private $provider;
	
	public function __construct($providerName){
		$this->session = new ImportTickerSession();
		$this->provider = $providerName;
	}
	
	public function Import($csvFileName){
		
	}
}

class ImportTickerSession{
	private $hasStarted;
	private $tickerIndex;
	
	public function __construct(){
		$this->hasStarted = FALSE;	
	}
	
	public function IsWaitingForStart(){
		if($this->hasStarted == FALSE)
			return TRUE;
		return FALSE;
	}
	
	public function Begin(){
		$this->hasStarted = TRUE;
		$this->tickerIndex = 0;
	}
	
	public function GetNextTickerIndex(){
		return $this->tickerIndex;
	}
	
	public function UpdateTickerIndex($index){
		if($this->hasStarted == TRUE)
			$this->tickerIndex = $index;
	}
	
	public function End(){
		$this->hasStarted = FALSE;
	}
}

?>
